/*
 * @Author: Wxx
 * @Date: 2022-03-01 16:16:23
 * @LastEditors: Wxx
 * @LastEditTime: 2022-03-01 16:29:42
 * @Description:
 */
import React, { Component } from "react";
import "./App.css";
import PortalDialog from "./PortalDialog";

export default class App extends Component {
  state = {
    isShow: false,
  };
  render() {
    return (
      <div id="app_07">
        <div id="left"></div>
        <div id="right">
          <button
            onClick={() => {
              this.setState({
                isShow: true,
              });
            }}
          >
            打开
          </button>
          {this.state.isShow && (
            <PortalDialog
              close={() => {
                this.setState({ isShow: false });
              }}
            >
              <h1>hhh</h1>
            </PortalDialog>
          )}
        </div>
      </div>
    );
  }
}
